﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Areas/Website/Views/Shared/Master.Master"
    Inherits="System.Web.Mvc.ViewPage<ProductViewModel>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="MainContent" runat="server">
    <%
        int pageCount = Convert.ToInt32(ViewData["PageCount"]);
        int pageIndex = Convert.ToInt32(ViewData["PageIndex"]);
        string hrefFormat = string.Format("<a href=\"{0}\">&nbsp;&nbsp;&nbsp;&nbsp;</a>", ViewData["Pager"]);
    %>
    <%-- 
   <div class="next">
        <%= (pageIndex< pageCount && pageCount>1) ?string.Format(hrefFormat,pageIndex+1):""  %>
    </div>
    <div class="front">
        <%= (pageIndex>1 && pageCount>1) ?string.Format(hrefFormat,pageIndex-1):""  %>
    </div>
    --%>
    <ul class="product_box">
        <% foreach (EProduct item in Model.ProductList)
           {
        %>
        <li><a href="<%=Url.Action("Preview",new{productId = item.ProductId}) %>">
            <img src="<%= string.Format("{0}/{1}/{2}",Model.ImageRoot,item.ProductId ,item.ImageName) %>"
                alt="" />
        </a>
            <div>
                <strong>
                    <%= item.ProductNo %></strong>
            </div>
        </li>
        <%
           
            } %>
    </ul>
    <div class="divPager2">
        <%= Html.Pager(ViewData["Pager"]) %>
    </div>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="head" runat="server">
    <%= HtmlMetaHelper.HtmlTitle(Model.Classify.Title,Model.Classify.KeyWords,Model.Classify.Description) %>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="cssLink" runat="server">
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="jsLink" runat="server">
</asp:Content>
<asp:Content ID="Content5" ContentPlaceHolderID="cssContent" runat="server">
    <style type="text/css">
        .product_box.
        {
            overflow: hidden;
        }
        .divPager2
        {
            text-align: center;
            clear:both;
            padding-top:10px;
            padding-bottom:4px;
        }
        .product_box strong
        {
            color: #732683;
            font-size: 14px;
        }
        .product_box li
        {
            float: left;
            width: 25%; /* margin-top: -20px;*/
            overflow: hidden;
            border-bottom: dotted 1px #e3c9e4;
            padding-bottom: 5px;
            text-align: center;
        }
        .product_box li img
        {
            width: 90%;
            margin-bottom: -10px;
        }
        .product_news
        {
            clear: both;
            overflow: hidden;
        }
        .product_news dl
        {
            overflow: hidden;
        }
        .product_news dt
        {
            padding: 5px 0;
        }
        .product_news dt span
        {
            padding: 5px 100px 5px 5px;
            color: #7F1084;
            font-weight: bold;
            border-bottom: 1px solid #7F1084;
        }
        .product_news dt a
        {
            color: #7F1084;
            float: right;
            margin-right: 40px;
        }
        
        .product_news dd
        {
            float: left;
            width: 40%;
            padding: 10px 5px;
            margin-right: 5px;
        }
        .product_news dd h3
        {
            font-size: 12px;
        }
        .product_news dd h6
        {
            font-size: 12px;
            margin-top: 5px;
            font-weight: normal;
            height: 30px;
            overflow: hidden;
        }
        .product_news .img
        {
            float: left;
            padding: 5px;
        }
        .product_news .img img
        {
            width: 100px;
        }
        .backHome
        {
            margin-top: -90px;
        }
        .next, .front
        {
            margin-top: 100px;
        }
    </style>
</asp:Content>
<asp:Content ID="Content6" ContentPlaceHolderID="jsContent" runat="server">
    <script type="text/javascript">
        $(function () {
            //$(".product_box li").eq(1).css("padding-top", "60px");
        });
    </script>
</asp:Content>
